#ifndef SCENE_H
#define SCENE_H

#include"D3DUtility.h"
#include"Camera.h"
#include"DirectionalLight.h"
#include"PointLight.h"
#include"RenderableObject.h"
#include"SkyDome.h"
#include<list>
#include<string>

using namespace std;

class Scene
{
public:
	Scene() 
	{ numObjects = 0; numActiveDirectionalLights = 0; numActivePointLights = 0; directionalLightsDirty = true; pointLightsDirty = true; backgroundColor = 0xff1e90ff; }
	void AddObject(RenderableObject *object);
	void AddDirectionalLight(DirectionalLight *light);
	void AddPointLight(PointLight *light);
	void SetSkyDome(string skyTexFile = "")
	{
		skyDome = SkyDome(skyTexFile);
		skyDome.build();
	}
	void Update();
	void Render();
public:
	Camera mainCamera;
	list<DirectionalLight*> directionalLights;
	list<PointLight*> pointLights;
	list<RenderableObject*> objects;

	SkyDome skyDome;

	int numObjects;
	int numActiveDirectionalLights;
	int numActivePointLights;

	bool directionalLightsDirty;
	bool pointLightsDirty;

	D3DCOLOR backgroundColor;

};

extern Scene scene;



#endif